package com.tuozixuan.user.api.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RestController;

import com.tuozixuan.user.api.UserApi;
import com.tuozixuan.user.model.User;
import com.tuozixuan.user.service.UserService;

@RestController
public class UserApiImpl implements UserApi {

	@Autowired
	private UserService userService;
	
	@Override
	public User getUserById(String id) {
		return userService.getUserById(Long.valueOf(id));
	}

	@Override
	public List<User> getAllUser() {
		return userService.getAllUser();
	}

}
